Skip to content

Conversation

@kryanbeane
Copy link
Contributor

@kryanbeane kryanbeane commented Oct 15, 2025

Issue link

RHOAIENG-35928

What changes have been made

Implemented HTTPRoute-based dashboard URLs for SDK v0.31.1 and below with automatic fallback to OpenShift Routes for backward compatibility.

  • Added _get_dashboard_url_from_httproute() to query Gateway API and construct https://{gateway-hostname}/ray/{namespace}/{cluster-name}
  • Updated cluster_dashboard_uri() and _map_to_ray_cluster() to try HTTPRoute first, fall back to OpenShift Routes if not found
  • Maintains backward compatibility with RHOAI for SDK v0.31.1 and below (OpenShift Routes) and Kind clusters (Ingresses)

Verification steps

The below needs to be tested on an oidc cluster / a cluster with HTTP Routes and Gateway API enabled (annoy Cathal for this)

from codeflare_sdk import Cluster, ClusterConfiguration
cluster = Cluster(ClusterConfiguration(
    name=<cluster_name>, 
    namespace=<namespace>,
    ....
)

print(cluster.cluster_dashboard_uri())
cluster.details() # click cluster link and log in, verify you get to the dashboard
cluster.status() # click cluster link and log in, verify you get to the dashboard
# For all of the abovem we expect: https://{gateway-hostname}/ray/<namespace>/<cluster-name>

Then test on your normal ROSA cluster with Openshift Routes and verify that the Dashboard worked as before

Lastly, test the same in Kind. 

Checks

  • I've made sure the tests are passing.
  • Testing Strategy
    • Unit tests
    • Manual tests
    • Testing is not required for this change

@codecov
Copy link

codecov bot commented Oct 15, 2025

Codecov Report

❌ Patch coverage is 85.71429% with 8 lines in your changes missing coverage. Please review.
✅ Project coverage is 94.34%. Comparing base (afe21b3) to head (dd84deb).
⚠️ Report is 1 commits behind head on main.

Files with missing lines Patch % Lines
src/codeflare_sdk/ray/cluster/cluster.py 85.71% 8 Missing ⚠️
Additional details and impacted files
@@            Coverage Diff             @@
##             main     #926      +/-   ##
==========================================
+ Coverage   94.24%   94.34%   +0.09%     
==========================================
  Files          24       24              
  Lines        2033     2068      +35     
==========================================
+ Hits         1916     1951      +35     
  Misses        117      117              

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.
  • 📦 JS Bundle Analysis: Save yourself from yourself by tracking and limiting bundle sizes in JS merges.

Copy link
Contributor

@laurafitzgerald laurafitzgerald left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

One question inline.

@kryanbeane kryanbeane force-pushed the RHOAIENG-35928 branch 2 times, most recently from 378708f to f5e154a Compare October 15, 2025 17:02
@openshift-merge-robot openshift-merge-robot added the needs-rebase Indicates a PR cannot be merged because it has merge conflicts with HEAD. label Oct 15, 2025
@openshift-merge-robot openshift-merge-robot removed the needs-rebase Indicates a PR cannot be merged because it has merge conflicts with HEAD. label Oct 15, 2025
@kryanbeane
Copy link
Contributor Author

/hold

@openshift-ci openshift-ci bot added the do-not-merge/hold Indicates that a PR should not merge because someone has issued a /hold command. label Oct 16, 2025
@laurafitzgerald
Copy link
Contributor

Verified backwards compatibility on Openshift Route.
Followed the step and the route on cluster.status and print(cluster.cluster_dashboard_uri()) was correct and RayDashboard was accessible once the cluster was fully up.
/approve
/lgtm

@openshift-ci openshift-ci bot added lgtm Indicates that a PR is ready to be merged. approved Indicates a PR has been approved by an approver from all required OWNERS files. labels Oct 16, 2025
@openshift-ci openshift-ci bot removed the lgtm Indicates that a PR is ready to be merged. label Oct 16, 2025
@laurafitzgerald
Copy link
Contributor

/lgtm
/approve

@openshift-ci openshift-ci bot added the lgtm Indicates that a PR is ready to be merged. label Oct 16, 2025
@openshift-ci
Copy link
Contributor

openshift-ci bot commented Oct 16, 2025

[APPROVALNOTIFIER] This PR is APPROVED

This pull-request has been approved by: chipspeak, laurafitzgerald

The full list of commands accepted by this bot can be found here.

The pull request process is described here

Needs approval from an approver in each of these files:
  • OWNERS [chipspeak,laurafitzgerald]

Approvers can indicate their approval by writing /approve in a comment
Approvers can cancel approval by writing /approve cancel in a comment

@kryanbeane
Copy link
Contributor Author

/unhold

@openshift-ci openshift-ci bot removed the do-not-merge/hold Indicates that a PR should not merge because someone has issued a /hold command. label Oct 16, 2025
@openshift-merge-bot openshift-merge-bot bot merged commit 538e780 into project-codeflare:main Oct 16, 2025
14 checks passed
@kryanbeane kryanbeane deleted the RHOAIENG-35928 branch October 16, 2025 09:54
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

approved Indicates a PR has been approved by an approver from all required OWNERS files. lgtm Indicates that a PR is ready to be merged.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants